package f.f0.f;

import f.a0;
import f.f0.g.c;
import f.f0.g.f;
import f.s;
import f.v;
import f.y;
import java.io.IOException;
import java.util.Objects;

/* compiled from: ConnectInterceptor */
public final class a implements s {
    public final v a;

    public a(v vVar) {
        this.a = vVar;
    }

    public a0 intercept(f.s.a aVar) throws IOException {
        f fVar = (f) aVar;
        y yVar = fVar.f;
        g gVar = fVar.b;
        int equals = yVar.b.equals("GET") ^ 1;
        v vVar = this.a;
        Objects.requireNonNull(gVar);
        try {
            c i = gVar.e(fVar.i, fVar.j, fVar.k, vVar.A, vVar.v, equals).i(vVar, aVar, gVar);
            synchronized (gVar.d) {
                gVar.n = i;
            }
            return fVar.b(yVar, gVar, i, gVar.b());
        } catch (IOException e) {
            throw new e(e);
        }
    }
}
